<?php

set_time_limit(0);
require_once ("common.php");

api();
function api() {
	$action = $_GET["a"];
	$apis = array("get","getCatalog", "getSlider", "set","setAll", "clear","info");
	if (!empty($action) && in_array($action, $apis)) {
		$class = new Data();
		if (method_exists($class, $action)) {
			call_user_func(array(&$class, $action));
		}
	} else {
		ajaxReturn(null, "error!", 0);
	}
}

?>
